package com.jiyun.controller;


import com.jiyun.login.pojo.finance.Refueling;
import com.jiyun.login.pojo.finance.RefuelingVo;
import com.jiyun.result.Result;
import com.jiyun.service.IRefuelingService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author author
 * @since 2025-02-14
 */
@RestController
@RequestMapping("/finance/car")
public class RefuelingController {

    //查询所有
    @Autowired
    private IRefuelingService refuelingService;

    @RequestMapping("All")
    public Result All(@RequestBody RefuelingVo refuelingVo){
        return refuelingService.All(refuelingVo);
    }

    //添加
    @RequestMapping("findAdd")
    public Result findAdd(@RequestBody Refueling refueling){
        return refuelingService.findAdd(refueling);
    }
    @RequestMapping("delete")
    public Result delete(Integer id){
        return refuelingService.delete(id);
    }


}
